<?php


namespace app\admin\controller;

use think\Request;
use app\common\model\Search as SearchModel;

class Search extends Controller
{
    /**
     * 代理财务明细搜索框
     * @return \think\response\Json
     * @author ymzhang
     * @access public
     * @date 2022-08-11 20:40
     */
    public function getDropdown(Request $request)
    {
        $type = $request->param('type');
        if (!in_array($type, [0, 1, 2, 3, 4])) {
            return fail('查询类别错误');
        }
        $search = new SearchModel();
        return $search->getDropdown($type);
    }
}